package com.example.armmvvm.ui.statemachine

import android.os.Bundle
import android.os.Looper
import com.example.arm.base.BaseActivity
import com.example.armmvvm.databinding.ActivityStateMachineBinding

/**
 *  author : yanghaozhang
 *  date : 2022/4/25 14:17
 *  description :
 */
class StateMachineActivity : BaseActivity<ActivityStateMachineBinding>() {
    private lateinit var stateMachine: OrderStateMachine
    override fun initView(savedInstanceState: Bundle?): ActivityStateMachineBinding {
        return ActivityStateMachineBinding.inflate(layoutInflater)
    }

    override fun initData(savedInstanceState: Bundle?) {
        stateMachine = OrderStateMachine("订单系统", Looper.getMainLooper(), binding)
        stateMachine.start()
    }
}